﻿using System;
using System.Collections.Generic;
using System.Data.SqlClient;
using System.Text;
using OpenAuth.Repository.Domain;
using OpenAuth.Repository.Interface;


namespace OpenAuth.App
{
    public class CYYGH001App : ApiBaseApp<CYYGH001>
    {
        public CYYGH001App(IApiRepository<CYYGH001> repository) : base(repository)
        {

        }
        /// <summary>
        /// 预约出诊科室查询
        /// </summary>
        /// <param name="ksrq">开始日期</param>
        /// <param name="jsrq">结束日期</param>
        /// <returns></returns>
        public IEnumerable<CYYGH001> QueryCYYGH001ByKsrq(string ksrq, string jsrq)
        {
            List<SqlParameter> param = new List<SqlParameter>();
            param.Add(new SqlParameter("@Ksrq", ksrq));
            param.Add(new SqlParameter("@Jsrq", jsrq));
            param.Add(new SqlParameter("@Czyh", "hf001"));
            var result = Query<CYYGH001>("exec usp_web_webtrans_CYYGH001 @ksrq=@Ksrq,@jsrq=@Jsrq,@czyh=@Czyh", param);
            return result;
        }
    }
}
